{% extends 'base.html' %}

{% load csrf_token_hack %}

{% block title %}Entelib{% endblock %}

{% block header %}Entelib{% endblock %}

{% block rest %}
{% if 1  %} <!-- turn this off for use apart from testing -->
<!-- development-only info -->
<div class="tip" style=" width:80% ; padding: 20px; text-align:center; margin: auto;">
  <p>Use <b>user</b> / <b>user</b> to log in as default user.</p>
  <p>Use <b>lib</b> / <b>lib</b> to log in as librarian</p>
  <p>Use <b>admin</b> / <b>admin</b> to acquire an extra power -- has all perms and is staff.</p>
  <p>Use <b>superadmin</b> / <b>superadmin</b> to acquire an extra super power -- absolute power (superuser in django terminology)</p>
</div>
<!-- development-only info -->
{% endif %}

<div id='login'>
<p>
<form action='.' method='post'>
{% csrf_token %}
    {{ form.non_field_errors }}
    <table>
        <tr>
            <td>Username: </td>
            <td><input type="text" name='username' value='' id='username' /></td> <td>{{form.username.errors}}</td>
        </tr><tr>
            <td>Password: </td>
            <td><input type='password' name='password' value='' id='password' /></td> <td>{{form.password.errors}}</td>
        </tr><tr>
        <td></td><td>
            <input type='submit' value='Login' />
        </td></tr>
    </table>
    <input type="hidden" name="next" value="/entelib/" />
    <p class="register">
      No account? <a href="/entelib/register/newuser">Register now</a>.
    <p>
</form></p>
</div>
{% endblock %}
